package com.mentalhealthplatform.studentV3.controller;

import com.mentalhealthplatform.appModels.CarouselItem;
import com.mentalhealthplatform.studentV3.service.CarouselItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author Pear
 */
@RestController
@RequestMapping("/api/v3/carousel")
public class CarouselItemController {

    @Autowired
    private CarouselItemService carouselItemService;

    @GetMapping("/images")
    public List<CarouselItem> getCarouselImages() {
        return carouselItemService.getAllCarouselItems();
    }
}
